package com.alstudio.utils.android.media.audio.recorder;

import com.alstudio.utils.android.media.audio.recorder.ALAudioRecorder.ALAudioRecordErroCode;

public interface ALAudioRecordCallback {

	/**
	 * 录音开始
	 * 
	 * @author Alonso Lee
	 */
	public void onRecording();

	/**
	 * 录音结束
	 * 
	 * @author Alonso Lee
	 */
	public void onStop();

	/**
	 * 录音出现异常错误
	 * 
	 * @author Alonso Lee
	 */
	public void onAudioError(ALAudioRecordErroCode code);

	/**
	 * 振幅变化
	 * 
	 * @param ratio
	 * @author Alonso Lee
	 */
	public void onAudioAmplitudeChanged(int ratio);

	/**
	 * 录音时长变化
	 * 
	 * @param second
	 * @author Alonso Lee
	 */
	public void onAudioProgressChanged(int second);

	/**
	 * 最大录音时长已到
	 * 
	 * @author Alonso Lee
	 */
	public void onAudioMaxDurationReached();

}
